﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using CQIE.TES.Model;
using CQIE.TES.WEB.USER.Models;

namespace CQIE.TES.IService
{
    public interface IRecordService
    {
        /// <summary>
        /// 保存学生记录
        /// </summary>
        /// <param name="evaId"></param>
        /// <param name="teacherid"></param>
        /// <param name="courseId"></param>
        /// <param name="studentId"></param>
        /// <param name="answerList"></param>
        /// <param name="question"></param>
        /// <returns></returns>
        bool Record(int evaId, int teacherid, int courseId, int studentId, List<int> answerList, List<int> question);

        /// <summary>
        /// 判断学生是否已完成该评测
        /// </summary>
        /// <param name="evaid"></param>
        /// <param name="teacherid"></param>
        /// <param name="courseId"></param>
        /// <param name="sid"></param>
        /// <returns>null未完成 完成会返回结果</returns>
        List<Record> IsRecorded(int evaid, int teacherid, int courseId, int sid);

        /// <summary>
        /// 判断系部、教研室、互评是否完成评教
        /// </summary>
        /// <param name="evaId"></param>
        /// <param name="teacherId"></param>
        /// <param name="aimTeacherId"></param>
        /// <param name="department"></param>
        /// <returns></returns>
        List<Record> IsRecorded(int evaId, int teacherId, int aimTeacherId, ENUM_EVA_TYPE mode);

        /// <summary>
        /// 判断教师自评是否完成评教
        /// </summary>
        /// <param name="evaId"></param>
        /// <param name="teacherId"></param>
        /// <returns></returns>
        List<Record> IsRecorded(int evaId, int teacherId);

        /// <summary>
        /// 保存系部评教结果
        /// </summary>
        /// <param name="evaId"></param>
        /// <param name="teacherId"></param>
        /// <param name="aimTeacherId"></param>
        /// <param name="answerList"></param>
        /// <param name="questionList"></param>
        /// <param name="mode"></param>
        /// <returns></returns>
        bool Record(int evaId, int teacherId, int aimTeacherId, List<int> answerList, List<int> questionList,
            ENUM_EVA_TYPE mode);
        /// <summary>
        /// 保存教师自评结果
        /// </summary>
        /// <param name="evaId"></param>
        /// <param name="teacherId"></param>
        /// <param name="answerList"></param>
        /// <param name="questionList"></param>
        /// <returns></returns>
        bool Record(int evaId, int teacherId, List<int> answerList, List<int> questionList);

        /// <summary>
        /// 保存教师互评结果
        /// </summary>
        /// <param name="evaId"></param>
        /// <param name="teacherId"></param>
        /// <param name="aimTeacherId"></param>
        /// <param name="answerList"></param>
        /// <param name="questionList"></param>
        /// <returns></returns>
        bool TeacherOtherRecord(int evaId, int teacherId, int aimTeacherId, List<int> answerList, List<int> questionList);

        /// <summary>
        /// 获取总走势图 每年优秀、良好人数走势 用于结果首页的Line和Pie
        /// </summary>
        /// <returns></returns>
        object GetEvaTrend();

        /// <summary>
        /// 获取大屏数据
        /// </summary>
        /// <returns>内容:rightData leftAbove leftCenter leftDown teacherId teacherName</returns>
        object GetDetailAllInfo(int tid);

        /// <summary>
        /// 获取table中的数据
        /// </summary>
        /// <param name="limit"></param>
        /// <param name="page"></param>
        /// <param name="searchString"></param>
        /// <param name="i"></param>
        /// <returns></returns>
        object GetTableData(int limit, int page, string searchString, out int count);
    }
}
